<?php
class Application_Model_Db_Users extends Zend_Db_Table_Abstract{
	protected $_name = 'users';
	protected $_primary = 'user_id';
	protected $_dependentTables = array('Application_Model_Db_UserDetails');
	function getDetails(){
		$temp = $this->fetchAll();
		$out = array();
		foreach($temp as $row){
			
			$dep = (array) $row->findDependentRowset('Application_Model_Db_UserDetails')->toArray();
			$out[] = array_merge($row->toArray(),$dep[0]);
		}
		return $out;
	}
}